<?php

session_start();

//连接数据库
$conn = @mysqli_connect('localhost','root','root');

if(!$conn)
{
    echo '连接MySql失败';
    exit;
}

$selected = mysqli_select_db($conn,'ceshi');

if(!$selected)
{
    echo '数据库不存在';
    exit;
}

mysqli_set_charset($conn,'utf8');

// 定义全局表前缀
$prefix = 'pre_';

//引入数据库连接文件
include_once('functions.php');